<div class="w_title_city title-css3">
	<div class="w_show_name">Chọn nhóm</div>
	<div class="w_city">
		<select>
			<option value="">- Chọn tỉnh thành -</option>
		</select>
	</div>
</div>
<div class="w_section border-shadow">
	<?php
	$sql = "SELECT id, title, name FROM #__sections WHERE published=1 ORDER BY ordering ASC, name ASC";
	$database->setQuery($sql);
	$lsNHNSection = $database->loadObjectList();
	echo '<ul>';
	for ($i=0; $i<count($lsNHNSection); $i++){
		//checked
		if ($task == 'blogsection'){
			if ($id == $lsNHNSection[$i]->id) 
				$checked = ' class="checked"';
			else 
				$checked = '';	
		}
		if ($task == 'blogcategory'){
			$sql = "SELECT section FROM #__categories WHERE id=".$id;
			$database->setQuery($sql);
			$database->loadObject($IDchecked);
			if ($lsNHNSection[$i]->id == $IDchecked->section)
				$checked = ' class="checked"';
			else 
				$checked = '';
		}
			
		$link = sefRelToAbs("index.php?option=com_content&task=blogsection&id=".$lsNHNSection[$i]->id).$lsNHNSection[$i]->name;
		echo '<li><a href="'.$link.'"'.$checked.'>'.$lsNHNSection[$i]->title.'</a></li>';
		if (($i+1)%4==0) echo '<div class="clearfix"></div>';
	}
	echo '</ul>';
	?>
</div>
<div class="clearfix"></div>
